    .typing {
        width: 4em;
      /*  white-space: nowrap;*/
        border-right: 2px solid transparent;
        animation: typing 3.5s steps(4, end), blink-caret 5s step-end infinite;
        overflow: hidden;
        
    }
    /* 打印效果 */
    @keyframes typing {
      from { width: 0; }
      to { width: 4em; }
    }
    /* 光标*/
    @keyframes blink-caret {
      from, to { box-shadow:transparent; }
      50% { box-shadow:currentColor;}
    }
 